/*
 * @Description: 登录公共API
 * @Author: wangwangwang
 * @Date: 2020-08-06 10:30:49
 * @LastEditors: wangwangwang
 * @LastEditTime: 2021-09-09 16:48:17
 */
import request from '@/utils/request'
/**
 * @Description: 登录
 * @Param: 
 * @Author: wangwangwang
 */

export function login(params) {
	return request({
		url: '/base/user/login',
		method: 'post',
		data: params,
	})
}

export function login2(params) {
	return request({
		url: '/base/user/login/v2',
		method: 'post',
		data: params,
	})
}

// 微信绑定当前登录用户
export function bindWechart(params) {
	return request({
		url: '/base/system/user/bingingWx',
		params
	})
}
// 微信解绑当前登录用户
export function unbindWechart(params) {
	return request({
		url: '/base/system/user/WxUnbound',
		params
	})
}
// 获取微信绑定用户
export function getWechatBindUser(params) {
	return request({
		url: '/base/system/user/getBingingWx',
		params
	})
}

// 微信登录接口
export function wechatLogin(data) {
	return request({
		url: '/base/user/login/WXLogin',
		method: 'post',
		data,
	})
}

export function getPermission(params) {
	return request({
		url: '/base/system/user/get_user_permission',
		method: 'get',
		params,
	})
}

/**
 * @Description: 退出登录
 * @Param: 
 * @Author: wangwangwang
 */
export function loginOut(params) {
	return request({
		url: '/base/system/user/logout',
		method: 'post',
		params,
	})
}
/**
 * @Description  修改密码
 * @Param 
 * @Author wangwangwang
 */
export function update_password(data) {
	return request({
		url: '/base/system/app/client/update_password',
		method: 'post',
		data,
	})
}
/**
 * @Description  修改用户信息
 * @Param 
 * @Author wangwangwang
 */
export function updateSignature(data) {
	return request({
		url: '/base/system/user/updateSignature',
		method: 'post',
		data,
	})
}

/**
 * @Description  积分
 * @Param 
 * @Author wangwangwang
 */
 export function getTotalIntergal(params) {
	return request({
		url: '/integral/api/integral/get_total_intergal',
		method: 'get',
		params,
	})
}

/**
 * @Description  积分列表
 * @Param 
 * @Author wangwangwang
 */
 export function pageIntergalDetails(data) {
	return request({
		url: '/integral/api/integral/page_intergal_details',
		method: 'post',
		data,
	})
}

/**
 * @Description: 待办
 * @param {*} data
 * @Author: wangwangwang
 */
export function backlogQueryPage(data) {
	return request({
		url: '/workflow/system/sign/task/join/center/backlogQueryPage',
		method: 'post',
		data,
	})
}

/**
 * @Description: 本人发起
 * @param {*} data
 * @Author: wangwangwang
 */
 export function myOutTaskQueryPage(data) {
	return request({
		url: '/workflow/system/sign/task/join/center/myOutTaskQueryPage',
		method: 'post',
		data,
	})
}
/**
 * @Description: 提交任务
 * @param {*} data
 * @Author: wangwangwang
 */
 export function submitTaskQueryPage(data) {
	return request({
		url: '/workflow/system/sign/task/join/center/submitTaskQueryPage',
		method: 'post',
		data,
	})
}
/**
 * @Description: 已办任务
 * @param {*} data
 * @Author: wangwangwang
 */
 export function finishedTaskQueryPage(data) {
	return request({
		url: '/workflow/system/sign/task/join/center/finishedTaskQueryPage',
		method: 'post',
		data,
	})
}
/**
 * @Description: 收藏任务
 * @param {*} data
 * @Author: wangwangwang
 */
 export function collectQueryPage(data) {
	return request({
		url: '/workflow/system/sign/task/join/center/collectQueryPage',
		method: 'post',
		data,
	})
}
/**
 * @Description: 跟踪事项
 * @param {*} data
 * @Author: wangwangwang
 */
 export function tailAfterTaskQueryPage(data) {
	return request({
		url: '/workflow/system/sign/task/join/center/tailAfterTaskQueryPage',
		method: 'post',
		data,
	})
}

/**
 * @Description: 添加
 * @param {*} data
 * @Author: wangwangwang
 */
export function saveTaskJoinCenter(data) {
	return request({
		url: '/workflow/system/sign/task/join/center/saveTaskJoinCenter',
		method: 'post',
		data,
	})
}

/**
 * @Description: 删除
 * @param {*} data
 * @Author: wangwangwang
 */
 export function deleteTaskJoinCenter(params) {
	return request({
		url: '/workflow/system/sign/task/join/center/deleteTaskJoinCenter',
		method: 'get',
		params,
	})
}

/**
 * @Description: 已关联任务
 * @param {*} data
 * @Author: wangwangwang
 */
export function taskJoinQueryPage(data) {
	return request({
		url: '/workflow/system/sign/task/join/center/taskJoinQueryPage',
		method: 'post',
		data,
	})
}
